package models;
 
import java.util.*;
import javax.persistence.*;

import play.db.jpa.*;
import play.data.validation.*;

@Entity
public class Employee extends Model {
	
/*	@Require
    @MaxSize(10)
	public String id;*/
	
    @Required
    @ManyToOne
    public MasLocation MasLoc;
    
    @Required
    @ManyToOne
    public Company CompanyID;
	
	@Required
    public Date IDExpiredDate;
	
	@Required
	@MaxSize(30)
	public String FirstName;
	
	@Required
	@MaxSize(30)
	public String LastName;
	
	@Required
	@MaxSize(10)
	public String Nationality;
	
	@Required
	@MaxSize(15)
	public String Gender;
	
	@Required
	@MaxSize(15)
	public String MaritalStatus;
	
	@Required
	@MaxSize(15)
	public String MilitaryStatus;
	
	@Required
	public Date BirthDay;
	
	@MaxSize(50)
	public String Address;
	
	@MaxSize(50)
	public String District;
	
	@MaxSize(50)
	public String Province;
	
	@MaxSize(5)
	public String ZipCode;
	
	@MaxSize(10)
	public String Country;
	
	@MaxSize(10)
	public String Telephone;
	
	@MaxSize(10)
	public String Mobile;
	
	@MaxSize(10)
	public String DrivingLicenseID;
	
	@MaxSize(10)
	public String DrivingType;
	
	public Date DrivingExpiredDate;
	
	public Date SecurityExpiredDate;
	
	@MaxSize(10)
	public String WorkPosition;
	
	@MaxSize(10)
	public String WorkStatus;
	
	@MaxSize(10)
	public String BloodGroup;
	
	@MaxSize(50)
	public String UnderlyingDisease;
	
	@MaxSize(5)
	public String FirstAid;
	
	public String toString() {
	    return FirstName + " " + LastName;
	}
	
}